home *** CD-ROM | disk | FTP | other *** search
/ InfoMagic Internet Tools 1995 April / Internet Tools.iso / appletalk / netatalk / afs / afsprivsrc.sit.hqx / AFS Privileges 1.50 / afsvcb.c next >
Encoding:
C/C++ Source or Header  |  1993-09-21  |  2.1 KB  |  58 lines

  1. /*
  2. ****************************************************************************
  3. *Copyright 1992 Regents of The University of Michigan - All Rights Reserved*
  4. *                                                                          *
  5. * Permission to use, copy, modify, and distribute this software and its    *
  6. * documentation for any purpose and without fee is hereby granted,         *
  7. * provided that the above copyright notice appears in all copies and that  *
  8. * both that copyright notice and this permission notice appear in          *
  9. * supporting documentation, and that the name of The University of Michigan*
  10. * not be used in advertising or publicity pertaining to distribution of    *
  11. * the software without specific, written prior permission. This software   *
  12. * is supplied as is without expressed or implied warranties of any kind.   *
  13. *                                                                          *
  14. *            Center for Information Technology Integration                 *
  15. *                  Information Technology Division                         *
  16. *                     The University of Michigan                           *
  17. *                       519 W. William Street                              *
  18. *                     Ann Arbor, Michigan 48103                            *
  19. *                         +1 313-764-5440                                  *
  20. *                       FAX: +1 313-764-4434                               *
  21. *                        info@citi.umich.edu                               *
  22. *                                                                          *
  23. ****************************************************************************
  24. */      
  25.  
  26. #include    <SysEqu.h>
  27. #include    <OSUtils.h>
  28. #include    <AppleTalk.h>
  29. #include    <Files.h>
  30.  
  31. #include    "AShare.h"
  32. #include    "xvcb.h"
  33. #include    "privileges.h"
  34.  
  35. AVCB *
  36. getVCBbyrefnum( short refnum )
  37. {
  38.     QHdrPtr    qh;
  39.     AVCB        *vcb;
  40.     
  41.     qh = GetVCBQHdr();
  42.     for ( vcb = (AVCB *)qh->qHead; vcb != NULL; vcb = (AVCB *)vcb->qLink ) {
  43.         if ( vcb->vcbVRefNum == refnum ) {
  44.             break;
  45.         }
  46.     }
  47.     return( vcb );
  48. }
  49.  
  50. Boolean
  51. isafsVCB( AVCB *vcb )
  52. {
  53.     if ( vcb->vcbFSID == 0 ) {
  54.         return( false );
  55.     }
  56.     return( true );
  57. }
  58.